import request from '@/utils/request'

// 查询车辆信息列表
export function listInfo(query) {
  return request({
    url: '/basic/info/list',
    method: 'get',
    params: query
  })
}

// 查询车辆信息详细
export function getInfo(vehicleId) {
  return request({
    url: '/basic/info/' + vehicleId,
    method: 'get'
  })
}

// 新增车辆信息
export function addInfo(data) {
  return request({
    url: '/basic/info',
    method: 'post',
    data: data
  })
}

// 修改车辆信息
export function updateInfo(data) {
  return request({
    url: '/basic/info',
    method: 'put',
    data: data
  })
}

// 删除车辆信息
export function delInfo(vehicleId) {
  return request({
    url: '/basic/info/' + vehicleId,
    method: 'delete'
  })
}

// 查询承运商列表
export function listCarrier(query) {
  return request({
    url: '/basic/carrier/list',
    method: 'get',
    params: query
  })
}

// 查询承运商详细
export function getCarrier(carrierId) {
  return request({
    url: '/basic/carrier/' + carrierId,
    method: 'get'
  })
}